package cn.exrick.xboot.modules.your.dao.mapper;

import cn.exrick.xboot.modules.your.entity.BedOrder;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * 陪护床数据处理层
 * @author chenyunxuan
 */
public interface BedOrderMapper extends BaseMapper<BedOrder> {

    @Select("select a.*,b.mobile from es_bed_order a left join es_user b on a.user_id=b.id ${ew.customSqlSegment}")
    IPage<BedOrder> pageOrder(Page initMpPage,  @Param(Constants.WRAPPER)QueryWrapper<BedOrder> qw);
}